export default [
  {
    name: '登录',
    path: '/user',
    layout: false,
    routes: [{ path: '/user/login', component: '@/pages/User/Login' }],
  },
  { name: '欢迎', path: '/welcome', icon: 'smile', component: '@/pages/Welcome' },
  {
    path: '/admin',
    icon: 'crown',
    access: 'canAdmin',
    name: '管理员页面',
    hideInMenu: true,
    routes: [
      { path: '/admin', redirect: '/admin/sub-page' },
      { path: '/admin/sub-page', component: '@/pages/Admin', name: '二级管理页' },
    ],
  },
  {
    name: '系统管理',
    path: '/system',
    icon: 'Setting',
    hideInMenu: true,
    access: 'canAdmin',
    routes: [
      { path: '/system/user', name: '用户管理', icon: 'User', component: '@/pages/System/User' },
      { path: '/system/role', name: '角色管理', icon: 'Team', component: '@/pages/System/Role' },
      { path: '/system/menu', name: '菜单管理', icon: 'Menu', component: '@/pages/System/User' },
      {
        path: '/system/dept',
        name: '部门管理',
        icon: 'Apartment',
        component: '@/pages/System/User',
      },
      {
        path: '/system/post',
        name: '岗位管理',
        icon: 'Contacts',
        component: '@/pages/System/User',
      },
      { path: '/system/dict', name: '字典管理', icon: 'Book', component: '@/pages/System/User' },
      {
        path: '/system/config',
        name: '参数设置',
        icon: 'Calculator',
        component: '@/pages/System/User',
      },
      {
        path: '/system/notice',
        name: '通知公告',
        icon: 'Message',
        component: '@/pages/System/User',
      },
      {
        path: '/system/log',
        name: '日志管理',
        icon: 'Snippets',
        routes: [
          {
            path: '/system/log/operlog',
            name: '操作日志',
            icon: 'Tool',
            component: '@/pages/System/User',
          },
          {
            path: '/system/log/logininfo',
            name: '登录日志',
            icon: 'Login',
            component: '@/pages/System/User',
          },
        ],
      },
    ],
  },
  {
    icon: 'table',
    hideInMenu: true,
    path: '/list',
    component: '@/pages/TableList',
    name: '表格页',
  },
  {
    icon: 'Home',
    hideInMenu: true,
    path: 'https://mortise-and-tenon.gitee.io/mortnon-docs/#/',
    name: '卯榫官网',
  },
  { path: '/', redirect: '/welcome' },
  { path: '*', layout: false, component: '@/pages/404' },
];
